home *** CD-ROM | disk | FTP | other *** search
/ SuperHack / SuperHack CD.bin / CODING / GRAPHICS / LSPSPR.ZIP / MCGA.H < prev    next >
Encoding:
C/C++ Source or Header  |  1996-04-19  |  488 b   |  38 lines

  1. #ifndef  _MCGA
  2. #define  _MCGA
  3.  
  4.  
  5. #include <dos.h>
  6.  
  7.  
  8. void     graphicon(void)
  9. {
  10.     union REGS mode;
  11.     mode.x.ax=0x13;
  12.     int86(0x10,&mode,&mode);
  13. }
  14.  
  15.  
  16. void     graphicoff(void)
  17. {
  18.     union REGS mode;
  19.     mode.x.ax=0x3;
  20.     int86(0x10,&mode,&mode);
  21. }
  22.  
  23.  
  24. void     setpalette(unsigned char *palette)
  25. {
  26.     int  loop;
  27.  
  28.     outportb(0x3c8,0);
  29.     for(loop=0;loop<768;loop++) {
  30.         outportb(0x3c9,palette[loop]);
  31.     }
  32. }
  33.  
  34.  
  35. #endif
  36.  
  37.  
  38. // NOERROR / GARGOYLE